package com.example.test.建造者;

import cn.hutool.json.JSONUtil;

import java.util.Date;

/**
 * @ClassNameJianzaozhe
 * @Description
 * @Author寂寞旅行
 * @Date2021/4/10 10:32
 * @Version V1.0
 **/
public class Jianzaozhe {
    public static void main(String[] args) {

        BasicArea basicArea = new BasicArea();
        basicArea.setId("1");
        basicArea.setName("1");
        basicArea.setCode("1");
        basicArea.setRemark("1");
        basicArea.setParentId("1");
        basicArea.setPath("1");
        basicArea.setDepth((byte) 0);
        basicArea.setExtend("1");
        basicArea.setSort(0);
        basicArea.setDeleteStatus(false);
        basicArea.setCreateUser("1");
        basicArea.setCreateTime(new Date());
        basicArea.setUpdateUser("8");
        basicArea.setUpdateTime(new Date());
        basicArea.setColumn1("2");
        basicArea.setColumn2("2");
        basicArea.setColumn3("2");
        basicArea.setColumn4("2");
        basicArea.setColumn5("2");


        Area builder = new AreaBuilder(basicArea)
                            .builderBasic()
                            .builderDate()
                            .builder();

        System.out.println(builder.toString());
        System.out.println(JSONUtil.toJsonStr(new Area()));


    }
}